package defpackage; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.OutputStream; import java.io.UnsupportedEncodingException; import java.util.Iterator; /* renamed from: zjo reason: default package */ public final class zjo { private static final String TAG = null; private OutputStream Bae; private zig jql; public zjo(OutputStream outputStream, zig zig) { ex.assertNotNull("os should not be null!", outputStream); ex.assertNotNull("ink should not be null!", zig); this.Bae = outputStream; this.jql = zig; } public zjo(String str, zig zig) { ex.assertNotNull("path should not be null!", str); ex.assertNotNull("ink should not be null!", zig); try { this.Bae = new FileOutputStream(str); } catch (FileNotFoundException e) { } this.jql = zig; } public final boolean gNs() { ex.assertNotNull("mWriter should not be null!", this.Bae); ex.assertNotNull("mInk should not be null!", this.jql); try { zip zip = new zip(this.Bae, "UTF8"); zig zig = this.jql; StringBuffer stringBuffer = new StringBuffer(); stringBuffer.append("<ink xmlns=\"http://www.w3.org/2003/InkML\" documentID=\"" + zig.AXu + "\">"); stringBuffer.append(zig.AXs.gLS()); Iterator<zit> it = zig.AXr.iterator(); while (it.hasNext()) { stringBuffer.append(it.next().a(zig.AXs)); } stringBuffer.append("</ink>"); zip.aeN(stringBuffer.toString()); return false; } catch (UnsupportedEncodingException e) { e.printStackTrace(); return false; } } public final boolean np() { ex.assertNotNull("mWriter should not be null!", this.Bae); ex.assertNotNull("mInk should not be null!", this.jql); try { new zip(this.Bae, "UTF8").aeN(this.jql.gLS()); return false; } catch (UnsupportedEncodingException e) { e.printStackTrace(); return false; } } }